import Vue from 'vue'
import Router from 'vue-router'
import home from "../view/home";
import information from "../components/information";
import sign_in from "../view/sign_in";
import setting from "../view/setting";
import showModel from "../view/showModel"
import upload from "../view/upload";
import temp from "../view/temp";
import home_A from "../view/home_A";
import updatePassWord from "../view/updatePassWord";
import seller_home from "../view/seller_home";
import DetailedInformation from "../view/DetailedInformation";
import Register from "../view/Register";
import loginA from "../view/loginA";
import good_temp from "../components/good_temp";
import CustomHome from "../view/CustomHome";
import UpdateCustomInformation from "../view/UpdateCustomInformation";
import CustomHistoryBuy from "../view/CustomHistoryBuy";
import TypeManage from "../view/TypeManage";
import TypeCard from "../components/TypeCard";
import Result from "../components/Result";

Vue.use(Router)

export default new Router({
  routes: [
    {path: '/', redirect: '/home_A'},
    {path: '/information', name: "information", component: information},
    {path: '/home', component: home},
    {path: '/sign_in', component: sign_in},
    {path: '/setting', component: setting},
    {path: '/showModel', name: "showModel", component: showModel},
    {path: '/upload', name: "upload", component: upload},
    {path: '/temp', name: "temp", component: temp},
    {path: '/home_A', name: "home_A", component: home_A},
    {path: '/updatePassWord', name: "updatePassWord", component: updatePassWord},
    {path: '/seller_home', name:"seller_home", component: seller_home},
    {path: '/DetailedInformation', name: "DetailedInformation", component: DetailedInformation},
    {path: '/Register', name: "Register", component: Register},
    {path: '/loginA', name: "loginA", component: loginA},
    {path: '/good_temp', name: "good_temp", component: good_temp},
    {
      path: '/CustomHome',
      name: "CustomHome",
      component: CustomHome,
      children: [
        {path: "/UpdateCustomInformation", name: "UpdateCustomInformation", component: UpdateCustomInformation},
        {path: "/CustomHistoryBuy", name: "CustomHistoryBuy", component: CustomHistoryBuy}
      ]
    },
    {
      path: "/TypeManage",
      name: "TypeManage",
      component: TypeManage,
    },
    {path: "/Result", name: Result, component: Result}
  ]
})
